﻿<Window x:Class="TriPhoto.TriPhotoApp"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="PhotoSort"
    WindowState = "Maximized"
    Topmost = "False"
    xmlns:pd="clr-namespace:TriPhoto"
    xmlns:properties="clr-namespace:TriPhoto.Properties"
    SizeToContent="Manual" WindowStyle="SingleBorderWindow">
    
  <Window.Resources>
    <!-- Style des menus fait avec un wrappanel -->
    <Style x:Key="MenuStyle" TargetType="{x:Type WrapPanel}">
       <Setter Property="Opacity" Value=".8" />
        <Style.Triggers>
          <EventTrigger RoutedEvent="Mouse.MouseEnter">
            <EventTrigger.Actions>
              <BeginStoryboard>
                <Storyboard>
                  <DoubleAnimation
									  Duration="0:0:0.2"
									  Storyboard.TargetProperty="Opacity"
									  To="1.0" />
                </Storyboard>
              </BeginStoryboard>
            </EventTrigger.Actions>
          </EventTrigger>

          <EventTrigger RoutedEvent="Mouse.MouseLeave">
            <EventTrigger.Actions>
              <BeginStoryboard>
                <Storyboard>
                  <DoubleAnimation
									  Duration="0:0:0.2"
									  Storyboard.TargetProperty="Opacity" />
                </Storyboard>
              </BeginStoryboard>
            </EventTrigger.Actions>
          </EventTrigger>
        </Style.Triggers>
    </Style>

    <!-- Style des images transfomées en bouton-->
    <Style x:Key="ImageBoutonStyle">
      <Setter Property="Image.Opacity" Value=".7" />
      <Setter Property="Image.Cursor" Value="Hand"/>
      <Style.Triggers>
        <EventTrigger RoutedEvent="Mouse.MouseEnter">
          <EventTrigger.Actions>
            <BeginStoryboard>
              <Storyboard>
                <DoubleAnimation
                  Duration="0:0:0.2"
                  Storyboard.TargetProperty="Opacity"
                  To="1.0" />
              </Storyboard>
            </BeginStoryboard>
          </EventTrigger.Actions>
        </EventTrigger>

        <EventTrigger RoutedEvent="Mouse.MouseLeave">
          <EventTrigger.Actions>
            <BeginStoryboard>
              <Storyboard>
                <DoubleAnimation
                  Duration="0:0:0.2"
                  Storyboard.TargetProperty="Opacity" />
              </Storyboard>
            </BeginStoryboard>
          </EventTrigger.Actions>
        </EventTrigger>
      </Style.Triggers>
    </Style>

    <LinearGradientBrush x:Key="WindowGradient" StartPoint="0,0.3" EndPoint="1,0">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#B2B6CAFF" Offset="0" />
        <GradientStop Color="#BFC3D5FF" Offset="0.1" />
        <GradientStop Color="#E0E4F0FF" Offset="0.3" />
        <GradientStop Color="#E6EAF5FF" Offset="0.5" />
        <GradientStop Color="#CFD7E2FF" Offset="0.6" />
        <GradientStop Color="#BFC5D3FF" Offset="0.8" />
        <GradientStop Color="#C4CBD8FF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ListBoxGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#90000000" Offset="0" />
        <GradientStop Color="#40000000" Offset="0.005" />
        <GradientStop Color="#10000000" Offset="0.04" />
        <GradientStop Color="#20000000" Offset="0.945" />
        <GradientStop Color="#60FFFFFF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ShoppingCartGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#90000000" Offset="0" />
        <GradientStop Color="#40000000" Offset="0.002" />
        <GradientStop Color="#10000000" Offset="0.02" />
        <GradientStop Color="#20000000" Offset="0.98" />
        <GradientStop Color="#60FFFFFF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ReflectionGradient" StartPoint="0,1" EndPoint="0,0">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#50000000" Offset="0" />
        <GradientStop Color="Transparent" Offset=".5" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#FDB6CADF" Offset="0" />
        <GradientStop Color="#FCC3C5FF" Offset="0.1" />
        <GradientStop Color="#FCC4D0EF" Offset="0.3" />
        <GradientStop Color="#FDB7C2DF" Offset="0.6" />
        <GradientStop Color="#FE95B3CF" Offset="0.8" />
        <GradientStop Color="#FE96AACF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="VerticalScrollGradient" StartPoint="0,0" EndPoint="1,0">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#FDB6CADF" Offset="0" />
        <GradientStop Color="#FCC3C5FF" Offset="0.1" />
        <GradientStop Color="#FCC4D0EF" Offset="0.3" />
        <GradientStop Color="#FDB7C2DF" Offset="0.6" />
        <GradientStop Color="#FE95B3CF" Offset="0.8" />
        <GradientStop Color="#FE96AACF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ComboBoxGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#B2B6CAFF" Offset="0" />
        <GradientStop Color="#B0B3C5FF" Offset="0.1" />
        <GradientStop Color="#BEE4E0FF" Offset="0.3" />
        <GradientStop Color="#B0D7E2FF" Offset="0.6" />
        <GradientStop Color="#B0C5D3FF" Offset="0.8" />
        <GradientStop Color="#C4CBD8FF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="GreetingCardGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#EEEEEE" Offset="0" />
        <GradientStop Color="#FFFFFF" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonUpGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="Transparent" Offset="0" />
        <GradientStop Color="#33000000" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonDownGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#10000000" Offset="0" />
        <GradientStop Color="#20000000" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonDisabledGradient" StartPoint="0,0" EndPoint="0,1">
      <LinearGradientBrush.GradientStops>
        <GradientStop Color="#10302A90" Offset="0" />
        <GradientStop Color="#10201040" Offset="1" />
      </LinearGradientBrush.GradientStops>
    </LinearGradientBrush>

    <!-- STYLES -->

    <!-- COMBOBOX STYLE -->

    <Style TargetType="{x:Type ComboBox}" >
      <Setter Property="Background" Value="{DynamicResource ComboBoxGradient}" />
      <Setter Property="BorderThickness" Value="0" />
      <Setter Property="Height" Value="18px" />
      <Setter Property="Foreground" Value="MidnightBlue" />
    </Style>

    <!-- PROGRESS BAR STYLE -->

    <Style TargetType="{x:Type ProgressBar}" >
      <Setter Property="Background" Value="{DynamicResource ComboBoxGradient}" />
      <Setter Property="BorderThickness" Value="1" />
      <Setter Property="BorderBrush" Value="Gray" />
      <Setter Property="Foreground" Value="MidnightBlue" />
    </Style>

    <!-- SCROLLBAR TEMPLATES -->

    <Style x:Key="Scrollbar_LineButton" TargetType="{x:Type RepeatButton}">
      <Setter Property="Template">
        <Setter.Value>
          <ControlTemplate TargetType="{x:Type RepeatButton}">
            <Border
							BorderBrush="Transparent"
							BorderThickness="1"
							CornerRadius="6"
							Background="{DynamicResource ButtonGradient}">
              <ContentPresenter x:Name="ContentSite" />
            </Border>
          </ControlTemplate>
        </Setter.Value>
      </Setter>
      <Setter Property="MinHeight" Value="17" />
      <Setter Property="MinWidth" Value="17" />
      <Setter Property="Foreground" Value="Gray" />
      <Setter Property="FontSize" Value="9pt" />
      <Setter Property="FontWeight" Value="Bold" />
      <Setter Property="FontFamily" Value="Lucida Sans" />
      <Setter Property="VerticalAlignment" Value="Center" />
      <Setter Property="HorizontalAlignment" Value="Center" />
    </Style>

    <Style x:Key="ScrollBar_TrackRepeater"  TargetType="{x:Type RepeatButton}">
      <Setter Property="IsTabStop" Value="false" />
      <Setter Property="Focusable" Value="false" />
      <Setter Property="Command" Value="ScrollBar.PageUpCommand" />
      <Setter Property="Template">
        <Setter.Value>
          <ControlTemplate TargetType="{x:Type RepeatButton}">
            <Rectangle Fill="Transparent" />
          </ControlTemplate>
        </Setter.Value>
      </Setter>
    </Style>

    <Style x:Key="ScrollBar_UpTrack" BasedOn="{StaticResource ScrollBar_TrackRepeater}" TargetType="{x:Type RepeatButton}">
      <Setter Property="Command" Value="ScrollBar.PageUpCommand" />
    </Style>

    <Style x:Key="ScrollBar_DownTrack" BasedOn="{StaticResource ScrollBar_TrackRepeater}" TargetType="{x:Type RepeatButton}">
      <Setter Property="Command" Value="ScrollBar.PageDownCommand" />
    </Style>

    <Style x:Key="ScrollBar_LeftTrack" BasedOn="{StaticResource ScrollBar_TrackRepeater}" TargetType="{x:Type RepeatButton}">
      <Setter Property="Command" Value="ScrollBar.PageLeftCommand" />
    </Style>

    <Style x:Key="ScrollBar_RightTrack" BasedOn="{StaticResource ScrollBar_TrackRepeater}" TargetType="{x:Type RepeatButton}">
      <Setter Property="Command" Value="ScrollBar.PageRightCommand" />
    </Style>

    <Style x:Key="ScrollBar_VerticalThumb" TargetType="{x:Type Thumb}">
      <Setter Property="Template">
        <Setter.Value>
          <ControlTemplate TargetType="{x:Type Thumb}">
            <Border CornerRadius="6"
							BorderBrush="Transparent"
							BorderThickness="1"
							Background="{DynamicResource VerticalScrollGradient}" />
          </ControlTemplate>
        </Setter.Value>
      </Setter>
      <Setter Property="MinHeight" Value="15" />
      <Setter Property="MinWidth" Value="15" />
    </Style>

    <Style x:Key="ScrollBar_HorizontalThumb" TargetType="{x:Type Thumb}">
      <Setter Property="Template">
        <Setter.Value>
          <ControlTemplate TargetType="{x:Type Thumb}">
            <Border CornerRadius="6"
							BorderBrush="Transparent"
							BorderThickness="1"
							Background="{DynamicResource ButtonGradient}" />
          </ControlTemplate>
        </Setter.Value>
      </Setter>
      <Setter Property="MinHeight" Value="15" />
      <Setter Property="MinWidth" Value="15" />
    </Style>

    <Style TargetType="{x:Type ScrollBar}">
      <Setter Property="Background" Value="Transparent" />
      <Setter Property="MinWidth" Value="15" />
      <Setter Property="Template">
        <Setter.Value>
          <ControlTemplate TargetType="{x:Type ScrollBar}">
            <Grid>
              <Grid.ColumnDefinitions>
                <ColumnDefinition Width="15"/>
              </Grid.ColumnDefinitions>
              <Grid.RowDefinitions>
                <RowDefinition Height="15" />
                <RowDefinition Height="*"/>
                <RowDefinition Height="15" />
              </Grid.RowDefinitions>
              <Border Grid.Row="1" BorderThickness="0" Background="Transparent" CornerRadius="4"/>
              <RepeatButton Grid.Row="0" Style="{DynamicResource Scrollbar_LineButton}" Command="ScrollBar.LineUpCommand" Content=" ^" />
              <Track Grid.Row="1" Name="PART_Track"  IsDirectionReversed="True">
                <Track.IncreaseRepeatButton>
                  <RepeatButton Style="{DynamicResource ScrollBar_DownTrack}"/>
                </Track.IncreaseRepeatButton>
                <Track.DecreaseRepeatButton>
                  <RepeatButton Style="{DynamicResource ScrollBar_UpTrack}"/>
                </Track.DecreaseRepeatButton>
                <Track.Thumb>
                  <Thumb Style="{DynamicResource ScrollBar_VerticalThumb}"/>
                </Track.Thumb>
              </Track>
              <RepeatButton Grid.Row="2" Style="{DynamicResource Scrollbar_LineButton}" Command="ScrollBar.LineDownCommand" Content=" v" />
            </Grid>
          </ControlTemplate>
        </Setter.Value>
      </Setter>
      <Style.Triggers>
        <Trigger Property="Orientation" Value="Horizontal" >
          <Setter Property="Background" Value="Transparent" />
          <Setter Property="MinHeight" Value="15" />
          <Setter Property="Template">
            <Setter.Value>
              <ControlTemplate TargetType="{x:Type ScrollBar}">
                <Grid>
                  <Grid.RowDefinitions>
                    <RowDefinition Height="17"/>
                  </Grid.RowDefinitions>
                  <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="17" />
                    <ColumnDefinition Width="*"/>
                    <ColumnDefinition Width="17" />
                  </Grid.ColumnDefinitions>
                  <Border Grid.Column="1" BorderThickness="0" Background="Transparent" CornerRadius="4"/>
                  <RepeatButton Grid.Column="0" Style="{DynamicResource Scrollbar_LineButton}" Command="ScrollBar.LineLeftCommand" Content=" &lt;" />
                  <Track Grid.Column="1" Name="PART_Track">
                    <Track.IncreaseRepeatButton>
                      <RepeatButton Style="{DynamicResource ScrollBar_RightTrack}"/>
                    </Track.IncreaseRepeatButton>
                    <Track.DecreaseRepeatButton>
                      <RepeatButton Style="{DynamicResource ScrollBar_LeftTrack}"/>
                    </Track.DecreaseRepeatButton>
                    <Track.Thumb>
                      <Thumb Style="{DynamicResource ScrollBar_HorizontalThumb}"/>
                    </Track.Thumb>
                  </Track>
                  <RepeatButton Grid.Column="2" Style="{DynamicResource Scrollbar_LineButton}" Command="ScrollBar.LineRightCommand" Content=" &gt;" />

                </Grid>
              </ControlTemplate>
            </Setter.Value>
          </Setter>
        </Trigger>
      </Style.Triggers>
    </Style>

    <Style TargetType="{x:Type pd:TriPhotoApp}">
      <Setter Property="Background" Value="{DynamicResource WindowGradient}" />
    </Style>

    <BitmapImage x:Key="NoirEtBlanc">
        <BitmapImage.UriSource>Bitmap\NoirEtBlanc.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Accept">
        <BitmapImage.UriSource>Bitmap\Accept.png</BitmapImage.UriSource>
    </BitmapImage>
      
    <BitmapImage x:Key="Add">
        <BitmapImage.UriSource>Bitmap\Add.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Aide2">
        <BitmapImage.UriSource>Bitmap\Aide.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Appliquer">
            <BitmapImage.UriSource>Bitmap\Appliquer.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Back">
        <BitmapImage.UriSource>Bitmap\Back.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Color">
        <BitmapImage.UriSource>Bitmap\Color.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Compare">
        <BitmapImage.UriSource>Bitmap\compare.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Corbeille">
        <BitmapImage.UriSource>Bitmap\Corbeille.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Exit">
        <BitmapImage.UriSource>Bitmap\Exit.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="Favoris">
        <BitmapImage.UriSource>Bitmap\Favoris.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="File">
        <BitmapImage.UriSource>Bitmap\file.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="GoDroite">
        <BitmapImage.UriSource>Bitmap\GoDroite.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="GoGauche">
        <BitmapImage.UriSource>Bitmap\GoGauche.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="Next">
        <BitmapImage.UriSource>Bitmap\Next.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="Open">
        <BitmapImage.UriSource>Bitmap\Open.png</BitmapImage.UriSource>
    </BitmapImage>
  
    <BitmapImage x:Key="Open2">
        <BitmapImage.UriSource>Bitmap\Open2.png</BitmapImage.UriSource>
    </BitmapImage>

    <BitmapImage x:Key="Save">
        <BitmapImage.UriSource>Bitmap\Save.png</BitmapImage.UriSource>
    </BitmapImage>

  </Window.Resources>

  
   <DockPanel LastChildFill="True">
       
    <!-- Définition des menus -->
    <WrapPanel Style="{DynamicResource MenuStyle}" HorizontalAlignment="Center" DockPanel.Dock="Top" Panel.ZIndex="1" Name="menuWrapPanel">
        
        <Button Name="ColorButton" ToolTip="{x:Static properties:Resources.BlackWhiteToolTip}" Click="ColorChange" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource NoirEtBlanc}"/>
        </Button>
        <Button Name="RotationUnClockWiseButton" ToolTip="{x:Static properties:Resources.RotationUnClockWiseToolTip}" Click="RotateClockWise" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource GoGauche}"/>
        </Button>
        <Button Name="RotationClockWiseButton" ToolTip="{x:Static properties:Resources.RotationClockWiseButtonToolTip}" Click="RotateUnClockWise" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource GoDroite}"/>
        </Button>
        <ToggleButton Name="CompareButton" ToolTip="{x:Static properties:Resources.CompareTooltip}" Background="WhiteSmoke"  Height="50" Width="50" Checked="CompareMode" Unchecked="CompareMode" IsChecked="False">
          <Image Source="{StaticResource Compare}"/>
        </ToggleButton>
      
        
        <Rectangle Height="50" Width="50" />
      
        <Button Name="ChooseDirectoryButton" ToolTip="{x:Static properties:Resources.ChooseDirectoryTooltip}" Background="WhiteSmoke"  Height="50" Width="50" Click="ChooseDirectory">
                <Image Source="{StaticResource Open2}"/>
        </Button>
        <Button Name="NewButton" ToolTip="{x:Static properties:Resources.NewTooltip}" Click="New" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource File}"/>
        </Button>
        <Button Name="OpenButton" ToolTip="{x:Static properties:Resources.OpenTooltip}" Click="Open" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource Open}"/>
        </Button>
        <Button Name="SaveButton" ToolTip="{x:Static properties:Resources.SaveTooltip}" Click="Save" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource Save}"/>
        </Button>
        <Button Name="ApplyButton" ToolTip="{x:Static properties:Resources.ApplyTooltip}" Click="Appliquer" Background="WhiteSmoke" Foreground="WhiteSmoke" BorderBrush="Black" Height="50" Width="50" >
          <Image Source="{StaticResource Appliquer}"/>
        </Button>
      
        <Rectangle Height="50" Width="50" />
      
        <Button Name="QuitButton" ToolTip="{x:Static properties:Resources.QuitTooltip}" Background="WhiteSmoke" Height="50" Width="50"  Click="ExitApplication">
          <Image Source="{StaticResource Exit}"/>
        </Button>
      
        <Rectangle Height="50" Width="50" />
      
        <Button Name="AddFolderButton" ToolTip="{x:Static properties:Resources.AddFolderTooltip}" Background="WhiteSmoke"  Height="50" Width="50" Click="AjoutRepertoire">
          <Image Source="{StaticResource Add}"/>
        </Button>
    </WrapPanel>


    <StackPanel Orientation="Horizontal" DockPanel.Dock="Bottom" Panel.ZIndex="0">
        <ProgressBar Name="LoadProgressBar" Width="200" Height="20" Minimum="0" Maximum="100" Visibility="Hidden" />
        <Label Name="LoadFileName" Width="200" Height="20" Foreground="White" Visibility="Hidden"/>
      </StackPanel>

    <!-- Espaces liste des images en entrée -->
    <Border BorderThickness="2" BorderBrush="Gray" CornerRadius="5" DockPanel.Dock="Left" AllowDrop="True" Name="ImageListStackBorder">
      <ScrollViewer Name="ImageListScrollViewer" VerticalScrollBarVisibility="Auto"   Panel.ZIndex="0">
        <WrapPanel Orientation="Vertical"  Name="ImageListStack" Width="200" />
      </ScrollViewer>
    </Border>

    <!-- Grille a droite contenant les images non determine et les images a supprimer-->
    <Grid DockPanel.Dock="Right" Width="200" Panel.ZIndex="0">
      <!-- Définition des tailles des elements 1 colonne et 2 lignes-->
      <Grid.ColumnDefinitions>
        <ColumnDefinition Width="40"/>
        <ColumnDefinition Width="160"/>
      </Grid.ColumnDefinitions>
      <Grid.RowDefinitions>
        <RowDefinition/>
        <RowDefinition />
        <RowDefinition />
      </Grid.RowDefinitions>

      <!-- Image a garder -->
      <WrapPanel VerticalAlignment="Center"  Grid.Column="0" Grid.Row="0">
        <Image Style="{DynamicResource ImageBoutonStyle}"  MouseDown="JeGarde" Name="ImageListAGarderButtonUp" Source="{StaticResource Next}"/>
        <Image Style="{DynamicResource ImageBoutonStyle}"  MouseDown="JeGardePlus" Name="ImageListAGarderButtonDown" Source="{StaticResource Back}"/>
      </WrapPanel>

      <Label Name="JeGardeLabel"  Grid.Column="1" Grid.Row="0" FontWeight="Bold" Foreground="DarkSlateBlue" Content="{x:Static properties:Resources.IKeepTooltip}"/>
      <Border BorderThickness="2" BorderBrush="Gray" CornerRadius="5" Grid.Column="1" Grid.Row="0" AllowDrop="True" Name="ImageListBorderAGarder">
        <Border.Background>
          <VisualBrush Stretch="Uniform">
            <VisualBrush.Visual>
              <Image Source="{StaticResource Favoris}" Opacity="0.75" />
            </VisualBrush.Visual>
          </VisualBrush>
        </Border.Background>
        <ScrollViewer VerticalScrollBarVisibility="Auto" Panel.ZIndex="0" Margin="0,18,0,0" HorizontalAlignment="Center" >
          <WrapPanel Orientation="Vertical"  Name="ImageListAGarder" AllowDrop="true"/>
        </ScrollViewer>
      </Border>

      <!-- Image a suppimer -->

      <WrapPanel VerticalAlignment="Center"   Grid.Column="0" Grid.Row="1">
        <Image Style="{DynamicResource ImageBoutonStyle}" MouseDown="JeSupprime" Name="ImageListASupprimerButtonUp" Source="{StaticResource Next}" />
        <Image Style="{DynamicResource ImageBoutonStyle}" MouseDown="JeSupprimePlus" Name="ImageListASupprimerButtonDown" Source="{StaticResource Back}"/>
      </WrapPanel>

      <Label  Grid.Column="1" Grid.Row="1" FontWeight="Bold" Foreground="DarkSlateBlue" Content="{x:Static properties:Resources.IDeleteTooltip}" />
      <Border BorderThickness="2" BorderBrush="Gray" CornerRadius="5" Grid.Column="1" Grid.Row="1" AllowDrop="True" Name="ImageListBorderASupprimer">
        <Border.Background>
          <VisualBrush Stretch="Uniform">
            <VisualBrush.Visual>
              <Image Source="{StaticResource Corbeille}" Opacity="0.75" />
            </VisualBrush.Visual>
          </VisualBrush>
        </Border.Background>
        <ScrollViewer VerticalScrollBarVisibility="Auto"   Panel.ZIndex="0" Margin="0,18,0,0" HorizontalAlignment="Center">
          <WrapPanel  Orientation="Vertical" Name="ImageListASupprimer"/>
        </ScrollViewer>
      </Border>

      <GridSplitter Grid.Row="0"
                          HorizontalAlignment="Center"
                          VerticalAlignment="Stretch"
                          Background="White"
                          ShowsPreview="True"
                          Height="5"
                   />

      <!-- Image non determiné -->

      <WrapPanel VerticalAlignment="Center" Grid.Column="0" Grid.Row="2">
        <Image Style="{DynamicResource ImageBoutonStyle}" MouseDown="JeSaisPas" Name="ImageListADeterminerButtonUp" Source="{StaticResource Next}"/>
        <Image Style="{DynamicResource ImageBoutonStyle}" MouseDown="JeSaisPasPlus" Name="ImageListADeterminerButtonDown" Source="{StaticResource Back}"/>
      </WrapPanel>

      <Label  Grid.Column="1" Grid.Row="2" FontWeight="Bold" Foreground="DarkSlateBlue" Content="{x:Static properties:Resources.IDontKnowToolTip}"/>
      <Border BorderThickness="2" BorderBrush="Gray" CornerRadius="5" Grid.Column="1" Grid.Row="2" AllowDrop="True" Name="ImageListBorderADeterminer">
        <Border.Background>
          <VisualBrush Stretch="Uniform">
            <VisualBrush.Visual>
              <Image Source="{StaticResource Aide2}" Opacity="0.75" />
            </VisualBrush.Visual>
          </VisualBrush>
        </Border.Background>
        <ScrollViewer VerticalScrollBarVisibility="Auto" Panel.ZIndex="0" Margin="0,18,0,0" HorizontalAlignment="Center">
          <WrapPanel Orientation="Vertical"  Name="ImageListADeterminer" AllowDrop="true"/>
        </ScrollViewer>
      </Border>
    </Grid>
    <!-- Image en popup -->
    <Canvas Name="ImagePopupCanvas" Panel.ZIndex="1"></Canvas>

    <!-- Espaces Image -->
    <Border BorderThickness="2" BorderBrush="Gray" CornerRadius="5" AllowDrop="True" Name="ImageStackBorder">
      <Grid  Name="ImageStack" Panel.ZIndex="0" HorizontalAlignment="Center" VerticalAlignment="Center">
        <Grid.ColumnDefinitions>
          <ColumnDefinition/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
          <RowDefinition/>
        </Grid.RowDefinitions>
      </Grid>
    </Border>
  </DockPanel>
</Window>
